<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>复习</title>
    <style>
        .box{
            background-color: rgb(238, 163, 163);
            width: 200px;
            height: 200px;
        }
    </style>
</head>
<body>
    <div class="box">
        一个盒子
    </div>
    <script>
        var box = document.querySelector('.box')
        var link = document.createElement('a')
        link.innerText = '网易'
        // link.href = 'www.163.com'
        link.setAttribute('href','www.163.com')
        

        //设置行内样式，也就是元素的style属性
        //连接号形式转换成驼峰
        // box.style.borderWidth = '2px'
        // box.style.borderColor = 'black'
        // box.style.borderStyle = 'solid'
        // box.style.color = 'green'
        //box.style.cssText = "color:orange;font-style:italic;letter-spacing:8px;";
        // box.replaceWith(link)
        Computor
        Compute
        Computed
    </script>
</body>
</html>